package OOP;
        import java.util.Scanner;
public class Zuoye {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        System.out.println("请输入作业名称");
        String name = new String(in.next());
        char[] names = name.toCharArray();
        System.out.println("请输入文件扩展名");
        String kuozhan = new String(in.next());
        boolean a=false;
        for (int j = 0; j < names.length; j++) {
            if ((int) names[j] >= 19968 && (int) names[j] <= 40869 &&
                    (kuozhan.contains("zip") || (kuozhan.contains("rar"))))
            {
                a=true;
            }
        }
        if(a){
            System.out.println("文件名称为"+name+"."+kuozhan);
            return;
        }
        System.out.println("输入失败");
    }
}
